{$CLEO}

0A95: enable_thread_saving


// This file was decompiled using SASCM.ini published by GTAG (http://gtag.gtagaming.com/opcode-database) on 14.6.2013
{$CLEO .CS}

//-------------MAIN---------------
thread 'CAR7' 


REPEAT 
WAIT 0
IF 0AAB: file_exists "CLEO\KEYS.INI"
THEN
    if and                                                                                    
    0AF0: 21@     "CLEO\KEYS.INI" "car_DRIVER" "CAMERA_MODE"                                 
    0AF0: 22@        "CLEO\KEYS.INI" "car_DRIVER" "STOP_car"                
    0AF0: 23@         "CLEO\KEYS.INI" "car_DRIVER" "driveby"                 
    0AF0: 24@ "CLEO\KEYS.INI" "car_DRIVER" "DRIVE_TO_MARKER"         
    0AF0: 25@        "CLEO\KEYS.INI" "car_DRIVER" "EXIT_car"                                                           
    then break                                                                                
    else                                                                                      
        0AF1: write_int 54 to_ini_file "CLEO\KEYS.INI" "car_DRIVER" "CAMERA_MODE"         
        0AF1: write_int 55 to_ini_file "CLEO\KEYS.INI" "car_DRIVER" "STOP_car"           
        0AF1: write_int 56 to_ini_file "CLEO\KEYS.INI" "car_DRIVER" "driveby"
        0AF1: write_int 57 to_ini_file "CLEO\KEYS.INI" "car_DRIVER" "DRIVE_TO_MARKER"
        0AF1: write_int 53 to_ini_file "CLEO\KEYS.INI" "car_DRIVER" "EXIT_car"                               
    end                                                                                       
END 
UNTIL IF 0AAB: file_exists "CLEO\KEYS.INI"

0adf: "DRIVER" "SET DRIVER ~1~" 

:CAR7_36E
wait 6 
if 
   Player.Defined($PLAYER_CHAR)
jf @CAR7_36E 
wait 250 
17@ = 1 
0209: 10@ = random_int_in_ranges 1 27 
if 
  10@ == 1 
jf @CAR7_3B8 
11@ = 400 
jump @CAR7_733 

:CAR7_3B8
if 
  10@ == 2 
jf @CAR7_3D9 
11@ = 405 
jump @CAR7_733 

:CAR7_3D9
if 
  10@ == 3 
jf @CAR7_3FA 
11@ = 409 
jump @CAR7_733 

:CAR7_3FA
if 
  10@ == 3 
jf @CAR7_41B 
11@ = 421 
jump @CAR7_733 

:CAR7_41B
if 
  10@ == 4 
jf @CAR7_43C 
11@ = 426 
jump @CAR7_733 

:CAR7_43C
if 
  10@ == 5 
jf @CAR7_45D 
11@ = 445 
jump @CAR7_733 

:CAR7_45D
if 
  10@ == 6 
jf @CAR7_47E 
11@ = 458 
jump @CAR7_733 

:CAR7_47E
if 
  10@ == 7 
jf @CAR7_49F 
11@ = 466 
jump @CAR7_733 

:CAR7_49F
if 
  10@ == 8 
jf @CAR7_4C0 
11@ = 467 
jump @CAR7_733 

:CAR7_4C0
if 
  10@ == 9 
jf @CAR7_4E1 
11@ = 470 
jump @CAR7_733 

:CAR7_4E1
if 
  10@ == 10 
jf @CAR7_502 
11@ = 479 
jump @CAR7_733 

:CAR7_502
if 
  10@ == 11 
jf @CAR7_523 
11@ = 490 
jump @CAR7_733 

:CAR7_523
if 
  10@ == 12 
jf @CAR7_544 
11@ = 492 
jump @CAR7_733 

:CAR7_544
if 
  10@ == 13 
jf @CAR7_565 
11@ = 507 
jump @CAR7_733 

:CAR7_565
if 
  10@ == 14 
jf @CAR7_586 
11@ = 516 
jump @CAR7_733 

:CAR7_586
if 
  10@ == 15 
jf @CAR7_5A7 
11@ = 529 
jump @CAR7_733 

:CAR7_5A7
if 
  10@ == 16 
jf @CAR7_5C8 
11@ = 540 
jump @CAR7_733 

:CAR7_5C8
if 
  10@ == 17 
jf @CAR7_5E9 
11@ = 546 
jump @CAR7_733 

:CAR7_5E9
if 
  10@ == 18 
jf @CAR7_60A 
11@ = 547 
jump @CAR7_733 

:CAR7_60A
if 
  10@ == 19 
jf @CAR7_62B 
11@ = 550 
jump @CAR7_733 

:CAR7_62B
if 
  10@ == 20 
jf @CAR7_64C 
11@ = 551 
jump @CAR7_733 

:CAR7_64C
if 
  10@ == 21 
jf @CAR7_66D 
11@ = 560 
jump @CAR7_733 

:CAR7_66D
if 
  10@ == 22 
jf @CAR7_68E 
11@ = 561 
jump @CAR7_733 

:CAR7_68E
if 
  10@ == 23 
jf @CAR7_6AF 
11@ = 566 
jump @CAR7_733 

:CAR7_6AF
if 
  10@ == 24 
jf @CAR7_6D0 
11@ = 567 
jump @CAR7_733 

:CAR7_6D0
if 
  10@ == 25 
jf @CAR7_6F1 
11@ = 579 
jump @CAR7_733 

:CAR7_6F1
if 
  10@ == 26 
jf @CAR7_712 
11@ = 580 
jump @CAR7_733 

:CAR7_712
if 
  10@ == 27 
jf @CAR7_733 
11@ = 585 
jump @CAR7_733 

:CAR7_733
Model.Load(11@)
Model.Load(#AK47)
Model.Load(#M4)
Model.Load(#MP5LNG)
Model.Load(#COLT45)
Model.Load(#SILENCED)
Model.Load(#DESERT_EAGLE)
Model.Load(#SAWNOFF)
Model.Load(#SHOTGSPA)
Model.Load(#MICRO_UZI)
Model.Load(#TEC9)
Model.Load(#CHROMEGUN)
Model.Load(#FAM1)
Model.Load(#FAM2)
Model.Load(#FAM3)
038B: load_requested_models 

if or
   not Model.Available(11@)
   not Model.Available(#FAM1)
   not Model.Available(#FAM2)
   not Model.Available(#FAM3)
jf @CAR7_7AF 
00BC: show_text_highpriority GXT 'ERROR' time 10000 flag 1 
end_thread 

:CAR7_7AF

wait 100 
04C4: store_coords_to 0@ 1@ 2@ from_actor $PLAYER_ACTOR with_offset 40.0 40.0 0.0 
04D3: get_nearest_car_path_coords_from 0@ 1@ 2@ type 0 store_to 3@ 4@ 5@ 
6@ = Car.Create(11@, 3@, 4@, 5@)
Car.Angle(6@) = 184.7214
Car.SetMaxSpeed(6@, 253.0)
Car.DoorStatus(6@) = 5
00AE: set_car 6@ traffic_behaviour_to 2 
Car.SetDriverBehaviour(6@, FollowRoad)
053F: set_car 6@ tires_vulnerability 0 
Car.SetImmunities(6@, 1, 1, 1, 1, 1)
0587: enable_car 6@ validate_position 0 
7@ = Actor.CreateAsDriver(Gang2, #FAM1, 6@)
8@ = Actor.CreateAsPassenger(Gang2, #FAM2, 6@, 1)
9@ = Actor.CreateAsPassenger(Gang2, #FAM1, 6@, 2)
if 
8431:   not car 6@ passenger_seat_free 0 
then 
    jump @cleaner 
end
if not Car.Wrecked(6@)
jf @cleaner 
0430: put_actor $PLAYER_ACTOR into_car 6@ passenger_seat 0 
Actor.Health(7@) = 500
Actor.Health(8@) = 500
Actor.Health(9@) = 500
0978: copy_decision_maker 65540 to 12@ 
0709: set_decision_maker 12@ on_event 36 taskID 1022 respect 0.0 hate 100.0 like 0.0 dislike 0.0 in_car 1 on_foot 0 // see *.ped files 
0709: set_decision_maker 12@ on_event 37 taskID 1022 respect 0.0 hate 100.0 like 0.0 dislike 0.0 in_car 1 on_foot 0 // see *.ped files 
0709: set_decision_maker 12@ on_event 36 taskID 1024 respect 0.0 hate 50.0 like 0.0 dislike 0.0 in_car 0 on_foot 1 // see *.ped files 
060B: set_actor 8@ decision_maker_to 12@ 
060B: set_actor 9@ decision_maker_to 12@ 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 7 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 7 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 20 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 20 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 17 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 17 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 18 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 18 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 6 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 6 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 4 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 4 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 5 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 5 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 9 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 9 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 10 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 10 // see ped.dat 
077A: set_actor 8@ acquaintance 4 to_actors_pedtype 11 // see ped.dat 
077A: set_actor 9@ acquaintance 4 to_actors_pedtype 11 // see ped.dat 
072F: enable_car 6@ stuck_check_distance 0.5 time 4000 and_restore_if stuck 1 flipped 1 unk_place_on_road_properly 1 to_path 7 // extended 03CC 
0209: 13@ = random_int_in_ranges 22 32 
0209: 14@ = random_int_in_ranges 22 32 
Actor.GiveWeaponAndAmmo(8@, 13@, 9999)
Actor.GiveWeaponAndAmmo(9@, 14@, 9999)
Actor.WeaponAccuracy(7@) = 100
Actor.WeaponAccuracy(8@) = 100
Actor.WeaponAccuracy(9@) = 100
0190: add_car 6@ to_flipped_check // 6 max 
0209: 15@ = random_int_in_ranges 1 255 
0209: 16@ = random_int_in_ranges 1 255
 
:loopj
while true
    repeat
    wait 0
    until if Player.Defined(0)
    if 0ab0: 21@ 
    then 
        wait 50
        0ab4: 17@ < 540 
        if 17@ == 1
        then 0ab3: 540 > 2
            camera.Restore_WithJumpCut
        else 0ab3: 540 > 1
            067C: put_camera_on_actor $PLAYER_ACTOR offset 0.1 -0.1 0.65 rotation 0.1 0.0 0.65 tilt 0.0 switchstyle 1
        end
    else
        if 0ab0: 22@                                                       
        then 
            wait 50                                                                    
            0ab4: 17@ < 541                                                      
            if 17@ == 1                                                          
            then 0ab3: 541 > 2                                                   
                Car.SetMaxSpeed(6@, 200.0)                           
                Car.SetSpeedInstantly(6@, 5.0)                       
            else 0ab3: 541 > 1                                                   
                Car.SetMaxSpeed(6@, 0.0)                             
                Car.SetSpeedInstantly(6@, 0.0)                       
            end                                                                  
        else                                                                      
            if 0ab0: 23@                                                                                               
            then 
                wait 50                                                                                                           
                0ab4: 17@ < 542                                                                                             
                if 17@ == 1                                                                                                 
                then 0ab3: 542 > 2                                                                                          
                    0209: 17@ = random_int_in_ranges 28 32                                                                                                 
                    Actor.GiveWeaponAndAmmo($PLAYER_ACTOR, 17@, 1E10)                                                                                                  
                    01B9: set_actor $PLAYER_ACTOR armed_weapon_to 17@                                                                                                  
                    0713: actor $PLAYER_ACTOR driveby_actor -1 car -1 point 0 0 0 radius 900.0 4 0 firing_rate 100
                    0ACA: show_text_box "~y~~H~ driveby on"                      
                else 0ab3: 542 > 1                                                                                          
                    0687: clear_actor $PLAYER_ACTOR task
                    0ACA: show_text_box "~y~~H~ driveby off"                                                                     
                end                                                                                                         
            else                                                                                                             
                if 0ab0: 24@                                                                           
                then wait 50                                                                                               
                    0ab4: 17@ < 543                                                                                 
                    if 17@ == 1                                                                                     
                    then 0ab3: 543 > 2                                                                              
                        if not Car.Wrecked(6@)                                                                      
                        then                                                                                        
                            if 0AB6: store_target_marker_coords_to 18@ 19@ 20@ // IF and SET                        
                            then 0ACA: show_text_box "~Y~~H~ DRIVE TO YOUR LOCATION"                                
                                Car.DriveTo(6@, 18@, 19@, 20@)                                                      
                            else 0ACA: show_text_box "~r~~H~ cant find LOCATION"                                    
                            end                                                                                     
                        end                                                                                         
                    else                                                                                            
                        0ab4: 17@ < 543                                                                             
                        if 17@ == 2                                                                                 
                        then                                                                                        
                            0ab3: 543 > 3                                                                           
                            if not Car.Wrecked(6@)                                                                  
                            then                                                                                    
                                Car.SetDriverBehaviour(6@, followroad)
                                0ACA: show_text_box "~y~~H~ command driver followroad"                                                       
                            end                                                                                     
                        else                                                                                        
                            0ab4: 17@ < 543                                                                         
                            if 17@ == 3                                                                             
                            then                                                                                    
                                0ab3: 543 > 1                                                                       
                                if not Car.Wrecked(6@)                                                              
                                then 0ACA: show_text_box "~y~~H~ command searh gangsters and driveby"                                                                               
                                    goto @searh_gangsters                                   
                                end                                                                                 
                            end                                                                                     
                        end                                                                                         
                    end                                                                                             
                else
                    if or
                        0ab0: 25@
                        00EE:   actor $PLAYER_ACTOR sphere 0 near_point 18@ 19@ radius 15.0 15.0 in_car                                                                            
                    then
                        goto @exit_car
                    end
                end
            end
        end
    end
    if or
        Car.Wrecked(6@)
        02BF:   car 6@ sunk 
        not Actor.Driving($PLAYER_ACTOR)
    then 
        jump @cleaner 
    end
end                                                                                                 
        
:exit_car 
if not Car.Wrecked(6@)                                                                          
then                                                                                             
    Car.SetSpeedInstantly(6@, 0.0)                                                               
    05CD: AS_actor $PLAYER_ACTOR exit_car 6@                                                     
    Car.SetSpeedInstantly(6@, 0.0)                                                               
    0ACD: show_text_highpriority "~Y~~H~ TO SEE THE FOLLOWING CJ" time 19000                     
    jump @cleaner                                                                                
end
jump @loopJ

:searh_gangsters
Actor.StorePos($PLAYER_ACTOR, 0@, 1@, 2@)                                                                                                                                                                                                         
if 0AE1: 27@ = random_actor_near_point 0@ 1@ 2@ in_radius 2650.0 find_next 1 pass_deads 0 //IF and SET                                                                                                                                                
then                                                                                                                                                                                                                                               
    089F: get_actor 27@ pedtype_to 28@                                                                                                                                                                                                                    
    if or                                                                                                                                                                                                                                                 
        28@ == 7                                                                                                                                                                                                                                          
        28@ == 9                                                                                                                                                                                                                                          
        28@ == 10                                                                                                                                                                                                                                         
        28@ == 11                                                                                                                                                                                                                                         
        28@ == 12                                                                                                                                                                                                                                         
        28@ == 13                                                                                                                                                                                                                                         
        28@ == 14                                                                                                                                                                                                                                         
    then                                                                                                                                                                                                                                                  
        if not Actor.Dead(27@)                                                                                                                                                                                                                            
        then                                                                                                                                                                                                                                              
            04C4: store_coords_to 29@ 30@ 31@ from_actor 27@ with_offset 4.0 4.0 0.0                                                                                                                                                                      
            if not Car.Wrecked(6@)                                                                                                                                                                                                                        
            then                                                                                                                                                                                                                                          
                Car.DriveTo(6@, 29@, 30@, 31@)                                                                                                                                                                                                            
                if 056D:   actor 8@ defined                                                                                                                                                                                                               
                then                                                                                                                                                                                                                                      
                    0713: actor 8@ driveby_actor 27@ car -1 point 0.0 0.0 0.0 radius 150.0 8 1 firing_rate 100                                                                                                                                            
                    if 056D:   actor 9@ defined                                                                                                                                                                                                           
                    then                                                                                                                                                                                                                                  
                        0713: actor 9@ driveby_actor 27@ car -1 point 0.0 0.0 0.0 radius 150.0 8 1 firing_rate 100                                                                                                                                        
                    end                                                                                                                                                                                                                                   
                    0ACA: show_text_box "~R~~H~DRIVE TO RANDOM GANGSTER"                                                                                                                                                                                  
                end                                                                                                                                                                                                                                       
            end                                                                                                                                                                                                                                           
        end                                                                                                                                                                                                                                               
    end                                                                                                                                                                                                                                                   
end                                                                                                                                                                                                                                                       
jump @loopj                                                                                                                                                                                                                                                          
        
:cleaner
0ACD: show_text_highpriority "~R~~H~SCRIPT UNLOADING" time 19000 
03E6: remove_text_box 
Car.RemoveReferences(6@)
Actor.RemoveReferences(7@)
Actor.RemoveReferences(8@)
Actor.RemoveReferences(9@)
wait 150 
END_THREAD